<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<jsp:directive.page import="entities.*"/>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Tous les events valide</title>
</head>
<body>
	<% 
  		String message = (String)request.getAttribute("message")==null?"":(String)request.getAttribute("message");
		String typesUser = (String)request.getAttribute("type")==null?"":(String)request.getAttribute("type");
		String title="Tous les Events proposes";
		if("MyFutureEvents".equals(typesUser)){
			title="Tous les Events que vous allez participer";
			
		}
		if("MyOrganisedEvents".equals(typesUser)){
			title="Tous les Events que vous avez propose";
			
		}
  		if(!message.equals("")){
  	%>
  		<%=message %>
  	<%} %>
  	

<h1><%=title %></h1>

    <hr/>
    <fieldset>

            <% 
    	List<Event> arrL=(List<Event>)request.getAttribute("allEvent");
    	Iterator<Event> it=arrL.iterator();
    	while(it.hasNext()){
    		Event tmEvent= it.next();
    %>
    		<a href="SerEvent?types=one&idEvent=<%=tmEvent.getIdEvent()%>&typesUser=<%=typesUser%>"><%=tmEvent.getName()%></a>
    		<br></br>
    		<span title="Lieu">Lieu :<%=tmEvent.getPlace()%></span>
    		<span title="Horaire">    Horaire :<%=tmEvent.getHour()%></span>
    		<span >    Nb de Participant :<%=tmEvent.getNbParticipants()%></span>
    		<hr/>
    		
    <%}%>
        
   
    </fieldset>

</body>
</html>